import request from '@/config/axios'

/**
 * 下载申请
 * @param params
 */
export const application = async (params: PageParam) => {
  return await request.post({ url: '/download/application', data: params })
}

/**
 * 分页查询个人下载申请列表
 * @param processInstanceId
 */
export const page = async (params: PageParam) => {
  return await request.get({ url: '/download/application/page', params })
}

export const detail = async (processInstanceId) => {
  return await request.get({ url: '/download/application/detail?id=' + processInstanceId })
}

export const download = async (id) => {
  return await request.download({ url: '/download/' + id })
}
